package com.kly.cashmall.module.products;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;

import androidx.annotation.Nullable;


import com.kly.cashmall.R;
import com.kly.cashmall.base.BaseBarActivity;
import com.kly.cashmall.base.app_action.ActionHeads;
import com.kly.cashmall.base.app_action.BaseActionHelper;
import com.kly.cashmall.event.HomeEvent;

import org.greenrobot.eventbus.EventBus;

/**
 * @author
 */
public class LoanSuccessActivity extends BaseBarActivity {

    public static Intent newIntent(Context context, String title, String msg) {
        Intent intent = new Intent(context, LoanSuccessActivity.class);
        intent.putExtra("title", title);
        intent.putExtra("msg", msg);
        return intent;
    }
    @Override
    protected void setView(@Nullable Bundle savedInstanceState) {
        setContentView(R.layout.activity_loan_success);
        setTitle(this.getResources().getString(R.string.order_success));

        EventBus.getDefault().post(new HomeEvent());


        bindText(R.id.tv_title, getIntent().getStringExtra("title"));
        bindText(R.id.tv_tip, getIntent().getStringExtra("msg"));
        bindView(R.id.tv_know,view -> {
            BaseActionHelper.with(this).handleAction(ActionHeads.LMActionHome);
        });
    }

    @Override
    protected void loadData() {

    }

    @Override
    protected void willDestroy() {
        super.willDestroy();
    }
}
